package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.FlowerMapper;
import com.ruoyi.system.domain.Flower;
import com.ruoyi.system.service.IFlowerService;

/**
 * 花店Service业务层处理
 * 
 * @author zzn
 * @date 2025-01-16
 */
@Service
public class FlowerServiceImpl implements IFlowerService 
{
    @Autowired
    private FlowerMapper flowerMapper;

    /**
     * 查询花店
     * 
     * @param flowerId 花店主键
     * @return 花店
     */
    @Override
    public Flower selectFlowerByFlowerId(Long flowerId)
    {
        return flowerMapper.selectFlowerByFlowerId(flowerId);
    }

    /**
     * 查询花店列表
     * 
     * @param flower 花店
     * @return 花店
     */
    @Override
    public List<Flower> selectFlowerList(Flower flower)
    {
        return flowerMapper.selectFlowerList(flower);
    }

    /**
     * 新增花店
     * 
     * @param flower 花店
     * @return 结果
     */
    @Override
    public int insertFlower(Flower flower)
    {
        return flowerMapper.insertFlower(flower);
    }

    /**
     * 修改花店
     * 
     * @param flower 花店
     * @return 结果
     */
    @Override
    public int updateFlower(Flower flower)
    {
        return flowerMapper.updateFlower(flower);
    }

    /**
     * 批量删除花店
     * 
     * @param flowerIds 需要删除的花店主键
     * @return 结果
     */
    @Override
    public int deleteFlowerByFlowerIds(Long[] flowerIds)
    {
        return flowerMapper.deleteFlowerByFlowerIds(flowerIds);
    }

    /**
     * 删除花店信息
     * 
     * @param flowerId 花店主键
     * @return 结果
     */
    @Override
    public int deleteFlowerByFlowerId(Long flowerId)
    {
        return flowerMapper.deleteFlowerByFlowerId(flowerId);
    }
}
